php check if string or number

53

php check if string or number -

 <?php if (is_numeric(887)) { echo "Yes"; } else { echo "No"; } ?>

php check if string or number -

 <?php if (is_numeric("cake")) { echo "Yes"; } else { echo "No"; } ?>

Comments

Submit
0 Comments